import Vue from 'vue';
import { DateUtil } from './date-util';
import { Constant } from '@/constant';

Vue.filter('dateFormatter', function(date: moment.Moment): string {
  return DateUtil.formatMoment(date, Constant.DATE);
});

Vue.filter('datetimeFormatter', function(date: moment.Moment): string {
  return DateUtil.formatMoment(date, Constant.DATE_TIME);
});
